package com.atguigu.tingshu.album.client;

import com.atguigu.tingshu.album.client.impl.AlbumInfoDegradeFeignClient;
import com.atguigu.tingshu.common.result.Result;
import com.atguigu.tingshu.model.album.AlbumInfo;
import com.atguigu.tingshu.model.album.BaseCategory3;
import com.atguigu.tingshu.vo.album.AlbumStatVo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

import java.util.List;

/**
 * <p>
 * 产品列表API接口
 * </p>
 *
 * @author qy
 */
@FeignClient(value = "service-album", fallback = AlbumInfoDegradeFeignClient.class,path = "/api/album/albumInfo/inner")
public interface AlbumInfoFeignClient {

    //远程调用专辑的基本信息
    @GetMapping("/getAlbumInfo/{albumId}")
    Result<AlbumInfo> getAlbumInforbc(@PathVariable(value = "albumId") Long albumId);

    @GetMapping("/getAlbumInfoStartByIdrpc/{albumId}")
    Result<AlbumStatVo> getAlbumInfoStartByIdrpc(@PathVariable(value = "albumId") Long albumId);

    @GetMapping("/getCategory3EntityByC1Id/{c1Id}")
    Result<List<BaseCategory3>> getCategory3EntityByC1Id(@PathVariable Long c1Id);
}
